//
//  FtNaviViewController.m
//  Feast
//
//  Created by 胡光健 on 2017/8/23.
//  Copyright © 2017年 mac. All rights reserved.
//

#import "FtNaviViewController.h"

@interface FtNaviViewController ()

@end

@implementation FtNaviViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    self.view.backgroundColor = HJColorRGB(255);
    [[UITabBar appearance] setBackgroundColor:HJColorRGB(255)];
    self.navigationBar.translucent = NO;
//    [self.navigationBar setBarTintColor:HJColor(248, 200, 22)];
    self.navigationBar.tintColor = HJColorRGB(255);
    self.navigationBar.titleTextAttributes = @{NSForegroundColorAttributeName: [UIColor whiteColor], NSFontAttributeName:[UIFont boldSystemFontOfSize:18]};
    [self.navigationBar setBackgroundImage:HJImage(@"navi") forBarMetrics:UIBarMetricsDefault];
    
}
- (void)pushViewController:(UIViewController *)viewController animated:(BOOL)animated {
    if (self.viewControllers.count > 0) {
        viewController.hidesBottomBarWhenPushed = YES;
        viewController.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"back_bai"] style:UIBarButtonItemStyleDone target:self action:@selector(back:)];
    }
    [super pushViewController:viewController animated:YES];
}

- (void)back:(UIBarButtonItem *)item {
    [self popViewControllerAnimated:YES];
}
@end
